package com.woniuxy.util;

import lombok.Getter;

@Getter
public enum ResponseEnum {
    //用户签约栏
    SIGN_USER_NOT_EXIST(500,"用户不存在"),
    SIGN_USER_EXIST(501,"用户已签约,请勿重复签约"),
    SIGN_OK(200,"签约成功"),
    SIGN_WAIT_PAY(502,"您有签约订单尚未支付"),
    //用户注册栏
    REGISTER_USER_EXIST(501,"用户已存在"),
    REGISTER_OK(200,"注册成功"),
    CODE_SEND_OK(200,"验证码发送成功"),
    REGISTER_CODE_ERROR(502,"验证码错误"),
    REGISTER_CODE_NOT_EXIST(503,"验证码已过期"),
    //用户登录栏
    LOGIN_USER_NOT_EXIST(500,"用户不存在"),
    LOGIN_USER_PASSWORD_ERROR(500,"密码错误"),
    LOGIN_OK(200,"登录成功"),
    //用户修改栏
    UPDATE_USER_OK(200,"修改成功"),
    UPDATE_USER_PASSWORD_ERROR(500,"原密码错误"),
    UPDATE_USER_PASSWORD_NOT_EQUAL(501,"新密码与原密码相同"),
    //token验证栏  使用的位置src/utils/request.js
    TOKEN_IS_NULL(401,"token为空"),
    TOKEN_ERROR(500,"token失效"),
    //服务记录表栏
    RECORD_QUERY_OK(200,"查询成功"),
    RECORD_ADD_OK(200,"添加成功"),
    RECORD_UPDATE_OK(200,"修改成功"),
    RECORD_DELETE_OK(200,"删除成功"),
    //通用栏
    OK(200,"操作成功"),
    FAIL(500,"操作失败"),
    SYS_BUSY(400,"系统繁忙");
    private Integer code;
    private String mag;
    ResponseEnum (Integer code,String msg){
        this.code=code;
        this.mag=msg;
    }
}
